Ext.define('TS.view.inv.ProductBatchNoList' ,{
    extend: 'Ext.grid.Panel',
    alias : 'widget.productbatchnolist',
    title : '商品批号',
    columnLines: true,
    bodyPadding:0,
    frame : true,//面板渲染
    closable: true,
    store:'inv.ProductBatchNoStore',
    /*fields: ['id','productId','batchNo','manufDate','expDate',
    'lastIncomeDate', 'lastIncomePrice','lastIncomeSupper'*/
    columns:[
        {header: '批号', dataIndex: 'batchNo', width:80,
        	field:{
				xtype:'textfield',
				allowBlank:false
			} 
        },
        {header: '生产日期', dataIndex: 'manufDate',width:80,renderer : Ext.util.Format.dateRenderer('Y-m-d'),
        	field:{
        		xtype:'datefield',
        		allowBlank:false,
        		format:'Y-m-d'
        	}
        },
        {header: '有效期', dataIndex: 'expDate',width:80,renderer : Ext.util.Format.dateRenderer('Y-m-d'),
        	field:{
        		xtype:'datefield',
        		allowBlank:false,
        		format:'Y-m-d'
        	}
        },
        {header: '最后进货', dataIndex: 'lastIncomeDate',width:80,renderer : Ext.util.Format.dateRenderer('Y-m-d'),
        	field:{
        		xtype:'datefield',
        		allowBlank:false,
        		format:'Y-m-d'
        	}
        },
        {header: '最后进价', dataIndex: 'lastIncomePrice',width:80,
        	field:{
        		xtype:'numberfield',
        		allowBlank:false
        	}
        }
    ],
    tbar :[
		{xtype:'button',action:'add',text:'添加',iconCls:'bill-add-button'},
		{xtype:'button',action:'upd',text:'修改',iconCls:'bill-edit-button'},
		{xtype:'button',action:'del',text:'删除',iconCls:'bill-delete-button'}
	],
	selType:'checkboxmodel',
	initComponent:function(){
		
		/*Ext.applyIf(this, {
			plugins:[
				Ext.create("Ext.grid.plugin.CellEditing",{
					clicksToEdit : 1
				})
				Ext.create('Ext.grid.plugin.RowEditing', {
		            clicksToEdit: 1
		        })
			]
		}),*/
		this.callParent(arguments);
	}
});